3.1.8 \(\int \frac {A+B \log (e (\frac {a+b x}{c+d x})^n)}{(a g+b g x)^4} \, dx\) [8]

Optimal. Leaf size=183 \[ -\frac {B n}{9 b g^4 (a+b x)^3}+\frac {B d n}{6 b (b c-a d) g^4 (a+b x)^2}-\frac {B d^2 n}{3 b (b c-a d)^2 g^4 (a+b x)}-\frac {B d^3 n \log (a+b x)}{3 b (b c-a d)^3 g^4}-\frac {A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )}{3 b g^4 (a+b x)^3}+\frac {B d^3 n \log (c+d x)}{3 b (b c-a d)^3 g^4} \]

[Out]

-1/9*B*n/b/g^4/(b*x+a)^3+1/6*B*d*n/b/(-a*d+b*c)/g^4/(b*x+a)^2-1/3*B*d^2*n/b/(-a*d+b*c)^2/g^4/(b*x+a)-1/3*B*d^3
*n*ln(b*x+a)/b/(-a*d+b*c)^3/g^4+1/3*(-A-B*ln(e*((b*x+a)/(d*x+c))^n))/b/g^4/(b*x+a)^3+1/3*B*d^3*n*ln(d*x+c)/b/(
-a*d+b*c)^3/g^4

________________________________________________________________________________________

Rubi [A]
time = 0.11, antiderivative size = 183, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, integrand size = 33, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.091, Rules used = {2547, 21, 46} \begin {gather*} -\frac {B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )+A}{3 b g^4 (a+b x)^3}-\frac {B d^3 n \log (a+b x)}{3 b g^4 (b c-a d)^3}+\frac {B d^3 n \log (c+d x)}{3 b g^4 (b c-a d)^3}-\frac {B d^2 n}{3 b g^4 (a+b x) (b c-a d)^2}+\frac {B d n}{6 b g^4 (a+b x)^2 (b c-a d)}-\frac {B n}{9 b g^4 (a+b x)^3} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(A + B*Log[e*((a + b*x)/(c + d*x))^n])/(a*g + b*g*x)^4,x]

[Out]

-1/9*(B*n)/(b*g^4*(a + b*x)^3) + (B*d*n)/(6*b*(b*c - a*d)*g^4*(a + b*x)^2) - (B*d^2*n)/(3*b*(b*c - a*d)^2*g^4*
(a + b*x)) - (B*d^3*n*Log[a + b*x])/(3*b*(b*c - a*d)^3*g^4) - (A + B*Log[e*((a + b*x)/(c + d*x))^n])/(3*b*g^4*
(a + b*x)^3) + (B*d^3*n*Log[c + d*x])/(3*b*(b*c - a*d)^3*g^4)

Rule 21

Int[(u_.)*((a_) + (b_.)*(v_))^(m_.)*((c_) + (d_.)*(v_))^(n_.), x_Symbol] :> Dist[(b/d)^m, Int[u*(c + d*v)^(m +
 n), x], x] /; FreeQ[{a, b, c, d, n}, x] && EqQ[b*c - a*d, 0] && IntegerQ[m] && ( !IntegerQ[n] || SimplerQ[c +
 d*x, a + b*x])

Rule 46

Int[((a_) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d*x
)^n, x], x] /; FreeQ[{a, b, c, d}, x] && NeQ[b*c - a*d, 0] && ILtQ[m, 0] && IntegerQ[n] &&  !(IGtQ[n, 0] && Lt
Q[m + n + 2, 0])

Rule 2547

Int[((A_.) + Log[(e_.)*(((a_.) + (b_.)*(x_))/((c_.) + (d_.)*(x_)))^(n_.)]*(B_.))*((f_.) + (g_.)*(x_))^(m_.), x
_Symbol] :> Simp[(f + g*x)^(m + 1)*((A + B*Log[e*((a + b*x)/(c + d*x))^n])/(g*(m + 1))), x] - Dist[B*n*((b*c -
 a*d)/(g*(m + 1))), Int[(f + g*x)^(m + 1)/((a + b*x)*(c + d*x)), x], x] /; FreeQ[{a, b, c, d, e, f, g, A, B, m
, n}, x] && NeQ[b*c - a*d, 0] && NeQ[m, -1] && NeQ[m, -2]

Rubi steps

\begin {align*} \int \frac {A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )}{(a g+b g x)^4} \, dx &=-\frac {A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )}{3 b g^4 (a+b x)^3}+\frac {(B n) \int \frac {b c-a d}{g^3 (a+b x)^4 (c+d x)} \, dx}{3 b g}\\ &=-\frac {A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )}{3 b g^4 (a+b x)^3}+\frac {(B (b c-a d) n) \int \frac {1}{(a+b x)^4 (c+d x)} \, dx}{3 b g^4}\\ &=-\frac {A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )}{3 b g^4 (a+b x)^3}+\frac {(B (b c-a d) n) \int \left (\frac {b}{(b c-a d) (a+b x)^4}-\frac {b d}{(b c-a d)^2 (a+b x)^3}+\frac {b d^2}{(b c-a d)^3 (a+b x)^2}-\frac {b d^3}{(b c-a d)^4 (a+b x)}+\frac {d^4}{(b c-a d)^4 (c+d x)}\right ) \, dx}{3 b g^4}\\ &=-\frac {B n}{9 b g^4 (a+b x)^3}+\frac {B d n}{6 b (b c-a d) g^4 (a+b x)^2}-\frac {B d^2 n}{3 b (b c-a d)^2 g^4 (a+b x)}-\frac {B d^3 n \log (a+b x)}{3 b (b c-a d)^3 g^4}-\frac {A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )}{3 b g^4 (a+b x)^3}+\frac {B d^3 n \log (c+d x)}{3 b (b c-a d)^3 g^4}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.12, size = 145, normalized size = 0.79 \begin {gather*} -\frac {6 \left (A+B \log \left (e \left (\frac {a+b x}{c+d x}\right )^n\right )\right )+\frac {B n \left ((b c-a d) \left (11 a^2 d^2+a b d (-7 c+15 d x)+b^2 \left (2 c^2-3 c d x+6 d^2 x^2\right )\right )+6 d^3 (a+b x)^3 \log (a+b x)-6 d^3 (a+b x)^3 \log (c+d x)\right )}{(b c-a d)^3}}{18 b g^4 (a+b x)^3} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(A + B*Log[e*((a + b*x)/(c + d*x))^n])/(a*g + b*g*x)^4,x]

[Out]

-1/18*(6*(A + B*Log[e*((a + b*x)/(c + d*x))^n]) + (B*n*((b*c - a*d)*(11*a^2*d^2 + a*b*d*(-7*c + 15*d*x) + b^2*
(2*c^2 - 3*c*d*x + 6*d^2*x^2)) + 6*d^3*(a + b*x)^3*Log[a + b*x] - 6*d^3*(a + b*x)^3*Log[c + d*x]))/(b*c - a*d)
^3)/(b*g^4*(a + b*x)^3)

________________________________________________________________________________________

Maple [F]
time = 0.05, size = 0, normalized size = 0.00 \[\int \frac {A +B \ln \left (e \left (\frac {b x +a}{d x +c}\right )^{n}\right )}{\left (b g x +a g \right )^{4}}\, dx\]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((A+B*ln(e*((b*x+a)/(d*x+c))^n))/(b*g*x+a*g)^4,x)

[Out]

int((A+B*ln(e*((b*x+a)/(d*x+c))^n))/(b*g*x+a*g)^4,x)

________________________________________________________________________________________

Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 433 vs. \(2 (172) = 344\).
time = 0.32, size = 433, normalized size = 2.37 \begin {gather*} -\frac {1}{18} \, B n {\left (\frac {6 \, b^{2} d^{2} x^{2} + 2 \, b^{2} c^{2} - 7 \, a b c d + 11 \, a^{2} d^{2} - 3 \, {\left (b^{2} c d - 5 \, a b d^{2}\right )} x}{{\left (b^{6} c^{2} - 2 \, a b^{5} c d + a^{2} b^{4} d^{2}\right )} g^{4} x^{3} + 3 \, {\left (a b^{5} c^{2} - 2 \, a^{2} b^{4} c d + a^{3} b^{3} d^{2}\right )} g^{4} x^{2} + 3 \, {\left (a^{2} b^{4} c^{2} - 2 \, a^{3} b^{3} c d + a^{4} b^{2} d^{2}\right )} g^{4} x + {\left (a^{3} b^{3} c^{2} - 2 \, a^{4} b^{2} c d + a^{5} b d^{2}\right )} g^{4}} + \frac {6 \, d^{3} \log \left (b x + a\right )}{{\left (b^{4} c^{3} - 3 \, a b^{3} c^{2} d + 3 \, a^{2} b^{2} c d^{2} - a^{3} b d^{3}\right )} g^{4}} - \frac {6 \, d^{3} \log \left (d x + c\right )}{{\left (b^{4} c^{3} - 3 \, a b^{3} c^{2} d + 3 \, a^{2} b^{2} c d^{2} - a^{3} b d^{3}\right )} g^{4}}\right )} - \frac {B \log \left ({\left (\frac {b x}{d x + c} + \frac {a}{d x + c}\right )}^{n} e\right )}{3 \, {\left (b^{4} g^{4} x^{3} + 3 \, a b^{3} g^{4} x^{2} + 3 \, a^{2} b^{2} g^{4} x + a^{3} b g^{4}\right )}} - \frac {A}{3 \, {\left (b^{4} g^{4} x^{3} + 3 \, a b^{3} g^{4} x^{2} + 3 \, a^{2} b^{2} g^{4} x + a^{3} b g^{4}\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((A+B*log(e*((b*x+a)/(d*x+c))^n))/(b*g*x+a*g)^4,x, algorithm="maxima")

[Out]

-1/18*B*n*((6*b^2*d^2*x^2 + 2*b^2*c^2 - 7*a*b*c*d + 11*a^2*d^2 - 3*(b^2*c*d - 5*a*b*d^2)*x)/((b^6*c^2 - 2*a*b^
5*c*d + a^2*b^4*d^2)*g^4*x^3 + 3*(a*b^5*c^2 - 2*a^2*b^4*c*d + a^3*b^3*d^2)*g^4*x^2 + 3*(a^2*b^4*c^2 - 2*a^3*b^
3*c*d + a^4*b^2*d^2)*g^4*x + (a^3*b^3*c^2 - 2*a^4*b^2*c*d + a^5*b*d^2)*g^4) + 6*d^3*log(b*x + a)/((b^4*c^3 - 3
*a*b^3*c^2*d + 3*a^2*b^2*c*d^2 - a^3*b*d^3)*g^4) - 6*d^3*log(d*x + c)/((b^4*c^3 - 3*a*b^3*c^2*d + 3*a^2*b^2*c*
d^2 - a^3*b*d^3)*g^4)) - 1/3*B*log((b*x/(d*x + c) + a/(d*x + c))^n*e)/(b^4*g^4*x^3 + 3*a*b^3*g^4*x^2 + 3*a^2*b
^2*g^4*x + a^3*b*g^4) - 1/3*A/(b^4*g^4*x^3 + 3*a*b^3*g^4*x^2 + 3*a^2*b^2*g^4*x + a^3*b*g^4)

________________________________________________________________________________________

Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 446 vs. \(2 (172) = 344\).
time = 0.36, size = 446, normalized size = 2.44 \begin {gather*} -\frac {6 \, {\left (A + B\right )} b^{3} c^{3} - 18 \, {\left (A + B\right )} a b^{2} c^{2} d + 18 \, {\left (A + B\right )} a^{2} b c d^{2} - 6 \, {\left (A + B\right )} a^{3} d^{3} + 6 \, {\left (B b^{3} c d^{2} - B a b^{2} d^{3}\right )} n x^{2} - 3 \, {\left (B b^{3} c^{2} d - 6 \, B a b^{2} c d^{2} + 5 \, B a^{2} b d^{3}\right )} n x + {\left (2 \, B b^{3} c^{3} - 9 \, B a b^{2} c^{2} d + 18 \, B a^{2} b c d^{2} - 11 \, B a^{3} d^{3}\right )} n + 6 \, {\left (B b^{3} d^{3} n x^{3} + 3 \, B a b^{2} d^{3} n x^{2} + 3 \, B a^{2} b d^{3} n x + {\left (B b^{3} c^{3} - 3 \, B a b^{2} c^{2} d + 3 \, B a^{2} b c d^{2}\right )} n\right )} \log \left (\frac {b x + a}{d x + c}\right )}{18 \, {\left ({\left (b^{7} c^{3} - 3 \, a b^{6} c^{2} d + 3 \, a^{2} b^{5} c d^{2} - a^{3} b^{4} d^{3}\right )} g^{4} x^{3} + 3 \, {\left (a b^{6} c^{3} - 3 \, a^{2} b^{5} c^{2} d + 3 \, a^{3} b^{4} c d^{2} - a^{4} b^{3} d^{3}\right )} g^{4} x^{2} + 3 \, {\left (a^{2} b^{5} c^{3} - 3 \, a^{3} b^{4} c^{2} d + 3 \, a^{4} b^{3} c d^{2} - a^{5} b^{2} d^{3}\right )} g^{4} x + {\left (a^{3} b^{4} c^{3} - 3 \, a^{4} b^{3} c^{2} d + 3 \, a^{5} b^{2} c d^{2} - a^{6} b d^{3}\right )} g^{4}\right )}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((A+B*log(e*((b*x+a)/(d*x+c))^n))/(b*g*x+a*g)^4,x, algorithm="fricas")

[Out]

-1/18*(6*(A + B)*b^3*c^3 - 18*(A + B)*a*b^2*c^2*d + 18*(A + B)*a^2*b*c*d^2 - 6*(A + B)*a^3*d^3 + 6*(B*b^3*c*d^
2 - B*a*b^2*d^3)*n*x^2 - 3*(B*b^3*c^2*d - 6*B*a*b^2*c*d^2 + 5*B*a^2*b*d^3)*n*x + (2*B*b^3*c^3 - 9*B*a*b^2*c^2*
d + 18*B*a^2*b*c*d^2 - 11*B*a^3*d^3)*n + 6*(B*b^3*d^3*n*x^3 + 3*B*a*b^2*d^3*n*x^2 + 3*B*a^2*b*d^3*n*x + (B*b^3
*c^3 - 3*B*a*b^2*c^2*d + 3*B*a^2*b*c*d^2)*n)*log((b*x + a)/(d*x + c)))/((b^7*c^3 - 3*a*b^6*c^2*d + 3*a^2*b^5*c
*d^2 - a^3*b^4*d^3)*g^4*x^3 + 3*(a*b^6*c^3 - 3*a^2*b^5*c^2*d + 3*a^3*b^4*c*d^2 - a^4*b^3*d^3)*g^4*x^2 + 3*(a^2
*b^5*c^3 - 3*a^3*b^4*c^2*d + 3*a^4*b^3*c*d^2 - a^5*b^2*d^3)*g^4*x + (a^3*b^4*c^3 - 3*a^4*b^3*c^2*d + 3*a^5*b^2
*c*d^2 - a^6*b*d^3)*g^4)

________________________________________________________________________________________

Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((A+B*ln(e*((b*x+a)/(d*x+c))**n))/(b*g*x+a*g)**4,x)

[Out]

Timed out

________________________________________________________________________________________

Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 375 vs. \(2 (172) = 344\).
time = 5.57, size = 375, normalized size = 2.05 \begin {gather*} -\frac {1}{18} \, {\left (\frac {6 \, {\left (B b^{2} n - \frac {3 \, {\left (b x + a\right )} B b d n}{d x + c} + \frac {3 \, {\left (b x + a\right )}^{2} B d^{2} n}{{\left (d x + c\right )}^{2}}\right )} \log \left (\frac {b x + a}{d x + c}\right )}{\frac {{\left (b x + a\right )}^{3} b^{2} c^{2} g^{4}}{{\left (d x + c\right )}^{3}} - \frac {2 \, {\left (b x + a\right )}^{3} a b c d g^{4}}{{\left (d x + c\right )}^{3}} + \frac {{\left (b x + a\right )}^{3} a^{2} d^{2} g^{4}}{{\left (d x + c\right )}^{3}}} + \frac {2 \, B b^{2} n - \frac {9 \, {\left (b x + a\right )} B b d n}{d x + c} + \frac {18 \, {\left (b x + a\right )}^{2} B d^{2} n}{{\left (d x + c\right )}^{2}} + 6 \, A b^{2} + 6 \, B b^{2} - \frac {18 \, {\left (b x + a\right )} A b d}{d x + c} - \frac {18 \, {\left (b x + a\right )} B b d}{d x + c} + \frac {18 \, {\left (b x + a\right )}^{2} A d^{2}}{{\left (d x + c\right )}^{2}} + \frac {18 \, {\left (b x + a\right )}^{2} B d^{2}}{{\left (d x + c\right )}^{2}}}{\frac {{\left (b x + a\right )}^{3} b^{2} c^{2} g^{4}}{{\left (d x + c\right )}^{3}} - \frac {2 \, {\left (b x + a\right )}^{3} a b c d g^{4}}{{\left (d x + c\right )}^{3}} + \frac {{\left (b x + a\right )}^{3} a^{2} d^{2} g^{4}}{{\left (d x + c\right )}^{3}}}\right )} {\left (\frac {b c}{{\left (b c - a d\right )}^{2}} - \frac {a d}{{\left (b c - a d\right )}^{2}}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((A+B*log(e*((b*x+a)/(d*x+c))^n))/(b*g*x+a*g)^4,x, algorithm="giac")

[Out]

-1/18*(6*(B*b^2*n - 3*(b*x + a)*B*b*d*n/(d*x + c) + 3*(b*x + a)^2*B*d^2*n/(d*x + c)^2)*log((b*x + a)/(d*x + c)
)/((b*x + a)^3*b^2*c^2*g^4/(d*x + c)^3 - 2*(b*x + a)^3*a*b*c*d*g^4/(d*x + c)^3 + (b*x + a)^3*a^2*d^2*g^4/(d*x
+ c)^3) + (2*B*b^2*n - 9*(b*x + a)*B*b*d*n/(d*x + c) + 18*(b*x + a)^2*B*d^2*n/(d*x + c)^2 + 6*A*b^2 + 6*B*b^2
- 18*(b*x + a)*A*b*d/(d*x + c) - 18*(b*x + a)*B*b*d/(d*x + c) + 18*(b*x + a)^2*A*d^2/(d*x + c)^2 + 18*(b*x + a
)^2*B*d^2/(d*x + c)^2)/((b*x + a)^3*b^2*c^2*g^4/(d*x + c)^3 - 2*(b*x + a)^3*a*b*c*d*g^4/(d*x + c)^3 + (b*x + a
)^3*a^2*d^2*g^4/(d*x + c)^3))*(b*c/(b*c - a*d)^2 - a*d/(b*c - a*d)^2)

________________________________________________________________________________________

Mupad [B]
time = 4.85, size = 349, normalized size = 1.91 \begin {gather*} \frac {2\,A\,a\,c\,d}{3\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}-\frac {A\,b\,c^2}{3\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}-\frac {A\,a^2\,d^2}{3\,b\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}-\frac {B\,b\,c^2\,n}{9\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}-\frac {B\,\ln \left (e\,{\left (\frac {a+b\,x}{c+d\,x}\right )}^n\right )}{3\,b\,g^4\,{\left (a+b\,x\right )}^3}-\frac {B\,b\,d^2\,n\,x^2}{3\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}+\frac {7\,B\,a\,c\,d\,n}{18\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}-\frac {11\,B\,a^2\,d^2\,n}{18\,b\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}-\frac {5\,B\,a\,d^2\,n\,x}{6\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}+\frac {B\,b\,c\,d\,n\,x}{6\,g^4\,{\left (a\,d-b\,c\right )}^2\,{\left (a+b\,x\right )}^3}-\frac {B\,d^3\,n\,\mathrm {atan}\left (\frac {a\,d\,1{}\mathrm {i}+b\,c\,1{}\mathrm {i}+b\,d\,x\,2{}\mathrm {i}}{a\,d-b\,c}\right )\,2{}\mathrm {i}}{3\,b\,g^4\,{\left (a\,d-b\,c\right )}^3} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((A + B*log(e*((a + b*x)/(c + d*x))^n))/(a*g + b*g*x)^4,x)

[Out]

(2*A*a*c*d)/(3*g^4*(a*d - b*c)^2*(a + b*x)^3) - (A*b*c^2)/(3*g^4*(a*d - b*c)^2*(a + b*x)^3) - (A*a^2*d^2)/(3*b
*g^4*(a*d - b*c)^2*(a + b*x)^3) - (B*b*c^2*n)/(9*g^4*(a*d - b*c)^2*(a + b*x)^3) - (B*d^3*n*atan((a*d*1i + b*c*
1i + b*d*x*2i)/(a*d - b*c))*2i)/(3*b*g^4*(a*d - b*c)^3) - (B*log(e*((a + b*x)/(c + d*x))^n))/(3*b*g^4*(a + b*x
)^3) - (B*b*d^2*n*x^2)/(3*g^4*(a*d - b*c)^2*(a + b*x)^3) + (7*B*a*c*d*n)/(18*g^4*(a*d - b*c)^2*(a + b*x)^3) -
(11*B*a^2*d^2*n)/(18*b*g^4*(a*d - b*c)^2*(a + b*x)^3) - (5*B*a*d^2*n*x)/(6*g^4*(a*d - b*c)^2*(a + b*x)^3) + (B
*b*c*d*n*x)/(6*g^4*(a*d - b*c)^2*(a + b*x)^3)

________________________________________________________________________________________